package day004.beanscope;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.FileSystemXmlApplicationContext;

public class ExamMain {
	public static void main(String[] args) {
		ApplicationContext context = new FileSystemXmlApplicationContext("/src/day004/beanscope/exam06.xml");
		BeanTest  beanSingleton1 = (BeanTest)context.getBean("beanSingleton");
		BeanTest  beanSingleton2 = (BeanTest)context.getBean("beanSingleton");
		
		System.out.println("beanSingleton1 : " + beanSingleton1);
		System.out.println("beanSingleton2 : " + beanSingleton2);
		
		BeanTest beanPrototype1 = (BeanTest)context.getBean("beanPrototype");
		BeanTest beanPrototype2 = (BeanTest)context.getBean("beanPrototype");

		System.out.println("beanPrototype1 : " + beanPrototype1);
		System.out.println("beanPrototype2 : " + beanPrototype2);		
	}
}
